#include <iostream>
#include <queue>
#include <map>
#include <unordered_map>
#include <vector>
#include <algorithm>
#include <cmath>
#include <string>
#include <cstring>
#include <set>
#include <unordered_set>
using namespace std;
typedef long long ll;
typedef unsigned long long Ull;
typedef pair<int,int> PII;
const int INF=0x3f3f3f3f;
int main()
{
	int t;
	cin>>t;
	while(t--)
	{
		ll l,r,m;
		cin>>l>>r>>m;
		ll d1=l-r;
		ll d2=r-l;
		ll m2=m-d1;
		ll m1=m-d2;//m1<m2

		if(m1<0) m1=0;
		int a,b,c;
		ll num=0;
		for(int i=l;i<=r;i++)
		{
		    num=m1/i;
		    if(m1%i==0 && num>0)
		    {
		    	a=i;
		    	break;
			}
			num++;
		    if(num*i<=m2)
		    {
		    	a=i;
		    	break;
			}
		}
		if(m-a*num==0)
		{
			cout<<a<<' '<<l<<' '<<l<<endl;
			continue;
		}
		else if(m-a*num>0)
		{
			cout<<a<<' '<<l+m-a*num<<' '<<l<<endl;
			continue;
		}
		else if(m-a*num<0)
		{
			cout<<a<<' '<<l<<' '<<l+a*num-m<<endl;
			continue;
		}
    }
		

	return 0;
}
